package com.summer.test.model;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

import com.summer.user.model.User;


@Entity
@Table(name = "system_loan_type")
@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE, region = "entityCache")
public class SystemLoanType implements java.io.Serializable{
	
	/**
	 * 借款产品
	 */
	private static final long serialVersionUID = -2917054325834201283L;
	private String id;
	private String name;
	private Integer status;
	private User operUser;
	private Date operDatetime;
	private User updateUser;
	private Date updateDatetime;
	
	
	public SystemLoanType(){}
	
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "Update_user")
	public User getUpdateUser() {
		return this.updateUser;
	}
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "Oper_user")
	public User getOperUser() {
		return operUser;
	}

	

	
	@Id
	@Column(name = "id", unique = true, nullable = false)
	public String getId() {
		return id;
	}
	@Column(name="name")
	public String getName() {
		return name;
	}
	@Column(name="status")
	public Integer getStatus() {
		return status;
	}
	
	@Column(name="Oper_datetime")
	public Date getOperDatetime() {
		return operDatetime;
	}
	
	@Column(name="Update_datetime")
	public Date getUpdateDatetime() {
		return updateDatetime;
	}


	public void setId(String id) {
		this.id = id;
	}


	public void setName(String name) {
		this.name = name;
	}


	public void setStatus(Integer status) {
		this.status = status;
	}


	public void setOperUser(User operUser) {
		this.operUser = operUser;
	}


	public void setOperDatetime(Date operDatetime) {
		this.operDatetime = operDatetime;
	}


	public void setUpdateUser(User updateUser) {
		this.updateUser = updateUser;
	}


	public void setUpdateDatetime(Date updateDatetime) {
		this.updateDatetime = updateDatetime;
	}
	
	
	
	
	

}
